Skip to content

token metedata#438

Merged
Devsol-01 merged 5 commits intoDevsol-01:mainfrom
Emeka000:good
Mar 27, 2026
Merged

token metedata#438
Devsol-01 merged 5 commits intoDevsol-01:mainfrom
Emeka000:good

Conversation

@Emeka000
Copy link
Copy Markdown
Contributor

closes #374

- Add claimed_tokens and unclaimed_tokens fields to UserRewards
- Add RewardToken key to RewardsDataKey for token contract address
- Add RewardsClaimed event and emit_rewards_claimed helper
- Implement claim_rewards() with double-claim protection via token::Client transfer
- Implement convert_points_to_tokens() to convert points to claimable tokens
- Expose set_reward_token, convert_points_to_tokens, claim_rewards entrypoints
- Guard claim_rewards with auth, pause check, and reentrancy guard
- Create src/token.rs with TokenMetadata struct (name, symbol, decimals, total_supply, treasury)
- Add TokenMetadata key to DataKey enum in storage_types.rs
- Call initialize_token() in contract constructor, assigning 1B NST supply to deployer
- Expose get_token_metadata() entrypoint for reading stored metadata
- Emit token/init event on initialization
- Token: name=Nestera, symbol=NST, decimals=7, supply=1_000_000_000_0000000
@vercel
Copy link
Copy Markdown

vercel bot commented Mar 27, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
nestera Ready Ready Preview, Comment Mar 27, 2026 5:49am

@drips-wave
Copy link
Copy Markdown

drips-wave bot commented Mar 27, 2026

@Emeka000 Great news! 🎉 Based on an automated assessment of this PR, the linked Wave issue(s) no longer count against your application limits.

You can now already apply to more issues while waiting for a review of this PR. Keep up the great work! 🚀

Learn more about application limits

@Devsol-01 Devsol-01 merged commit daaeb04 into Devsol-01:main Mar 27, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Contract] - Token Metadata & Initialization

2 participants